PATHMac OS 8 and 9 Developer Documentation > Interapplication Communication > AppleScript for Scripters >

AppleScript Language Guide

   

Values and Constants

Values are data that can be represented, stored, and manipulated in scripts. AppleScript recognizes many types of values, including character strings, real numbers, integers, lists, and dates. Values are different from application objects, which can also be manipulated from AppleScript but are contained in applications or their documents. Objects are described in Objects and References.

Each value belongs to a value class , which is a category of values that are represented in the same way and respond to the same operators. To find out how to represent a particular value, or which operators it responds to, check its value class definition. AppleScript can coerce a value of one class into a value of another. The possible coercions depend on the class of the original value.

This chapter describes how to interpret value class definitions, discusses the common characteristics of all value classes, and presents definitions of many value classes supported in AppleScript. It also describes how to coerce values and describes various types of constant values you can use in scripts.

Value classes and coercions are described in the following sections:

A constant is a reserved word with a predefined value. You can use constants to supply values in scripts. Constants are described in the following sections:


© 1999 Apple Computer, Inc. – (Last Updated 21 May 99)